package com.guizi.halftimesroom.view;

import android.content.Context;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.guizi.halftimesroom.R;

/**
 * Created by Alan on 2016/7/20.
 */
public class TagPurpleView extends LinearLayout{
    private Context mContext;
    private TextView textView;
    public TagPurpleView(Context context) {
        this(context,null);
    }

    public TagPurpleView(Context context, AttributeSet attrs) {
        this(context, attrs,0);
    }

    public TagPurpleView(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
        initView(context);
    }

    private void initView(Context context) {
        this.mContext =context;
        View view = LayoutInflater.from(mContext).inflate(R.layout.tag_purple, this);
        textView = (TextView) view.findViewById(R.id.tv_tag_purple);
    }
    public void setData(String s){
        textView.setText(s);
    }
}
